
package ttOrder.service;

import java.util.ArrayList;
import java.util.List;

//import javax.annotation.Resource;

import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.stereotype.Controller;
import org.springframework.stereotype.Service;
//import org.springframework.ui.Model;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//import org.springframework.web.servlet.ModelAndView;
import org.springframework.transaction.annotation.Transactional;

import ttOrder.dao.inter.UserMapper;
import ttOrder.model.po.User;

@Service
public class commonService {
	/*
	@Autowired
	private UserMapper userMapper;

	public List<User> users (){
		List<User> list = new ArrayList<User>();
		User u1 = new User();
		u1.setId(1);
		u1.setName("u1");
		u1.setPassword("u1pass");
		list.add(u1);
		list = userMapper.selectAll();
		return list;
	}
	
	/*public List<User> testUsers (){
		return userMapper.getAllUser();
	}
	
	@Transactional
	public int testInsert (User user){
		if (user != null) {
			userMapper.save(user);
			return 1;
		}
		return 0;
	}*/

	/*@Transactional
	public int testDelete(User user) {
		if (user != null) {
			userMapper.delete(user);
			return 1;
		}
		return 0;
	}*/
	
}
